<!doctype html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <title>Software Metrics By Software Engineering</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta content="Premium Multipurpose Admin & Dashboard Template" name="description">
    <meta content="Themesdesign" name="author">

    <!-- datepicker -->
    <link href="/css/datepicker.min.css" rel="stylesheet" type="text/css">

    <!-- jvectormap -->
    <link href="/css/jqvmap.min.css" rel="stylesheet">

    <!-- Bootstrap Css -->
    <link href="/css/bootstrap.min.css" rel="stylesheet" type="text/css">
    <!-- Icons Css -->
    <link href="/css/icons.min.css" rel="stylesheet" type="text/css">
    <!-- App Css-->
    <link href="/css/app.min.css" rel="stylesheet" type="text/css">

</head>

<body data-topbar="colored">

<!-- Begin page -->
<div id="layout-wrapper">

    <header id="page-topbar">
        <div class="navbar-header">
            <div class="d-flex">
                <!-- LOGO -->
                <div class="navbar-brand-box">
                    <a href="" class="logo logo-dark">
                                <span class="logo-sm">
                                    <img src="/newImage/logo.png" alt="" height="60">
                                </span>
                        <span class="logo-lg">
                                    <img src="/newImage/logo.png" alt="" height="60">
                                </span>
                    </a>

                    <a href="" class="logo logo-light">
                                <span class="logo-sm">
                                    <img src="/picture/logo-sm-light.png" alt="" height="22">
                                </span>
                        <span class="logo-lg">
                                    <img src="/picture/logo-light.png" alt="" height="20">
                                </span>
                    </a>
                </div>

                <button type="button" class="btn btn-sm px-3 font-size-24 header-item waves-effect" id="vertical-menu-btn">
                    <i class="mdi mdi-backburger"></i>
                </button>

                <!-- App Search-->
                <form class="app-search d-none d-lg-block">
                    <div class="position-relative">
                        <input type="text" class="form-control" placeholder="Search...">
                        <span class="mdi mdi-magnify"></span>
                    </div>
                </form>
            </div>

            <div class="d-flex">

                <div class="dropdown d-inline-block d-lg-none ml-2">
                    <button type="button" class="btn header-item noti-icon waves-effect" id="page-header-search-dropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                        <i class="mdi mdi-magnify"></i>
                    </button>
                    <div class="dropdown-menu dropdown-menu-lg dropdown-menu-right p-0" aria-labelledby="page-header-search-dropdown">

                        <form class="p-3">
                            <div class="form-group m-0">
                                <div class="input-group">
                                    <input type="text" class="form-control" placeholder="Search ..." aria-label="Recipient's username">
                                    <div class="input-group-append">
                                        <button class="btn btn-primary" type="submit"><i class="mdi mdi-magnify"></i></button>
                                    </div>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
            </div>


            <div class="col-md-4">
                <div class="float-right d-none d-md-block">
                    <div class="dropdown">
                        <button class="btn btn-light btn-rounded dropdown-toggle" type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                            <i class="mdi mdi-settings-outline mr-1"></i> Settings
                        </button>
                        <div class="dropdown-menu dropdown-menu-right dropdown-menu-animated">
                            <a class="dropdown-item" href="#">Action</a>
                            <a class="dropdown-item" href="#">Another action</a>
                            <a class="dropdown-item" href="#">Something else here</a>
                            <div class="dropdown-divider"></div>
                            <a class="dropdown-item" href="#">Separated link</a>
                        </div>
                    </div>
                </div>
            </div>
        </div>

    </header>

    <!-- ========== Left Sidebar Start ========== -->
    <div class="vertical-menu">

        <div data-simplebar="" class="h-100">

            <!--- Sidemenu -->
            <div id="sidebar-menu">
                <!-- Left Menu Start -->
                <ul class="metismenu list-unstyled" id="side-menu">
                    <li class="menu-title">Menu</li>

                    <li>
                        <a href="/to/index" class="waves-effect">
                            <div class="d-inline-block icons-sm mr-1"><i class="uim uim-airplay"></i></div>
                            <span>首            页</span>
                        </a>
                    </li>
                    <li class="menu-title">Basic</li>
                    <li>
                        <a href="/size/goToSize" class="waves-effect">
                            <div class="d-inline-block icons-sm mr-1"><i class="uim uim-window-grid"></i></div>
                            <span>传统度量</span>
                        </a>
                    </li>

                    <li>
                        <a href="/to/functionPoint" class="waves-effect">
                            <div class="d-inline-block icons-sm mr-1"><i class="uim uim-schedule"></i></div>
                            <span>功能点度量</span>
                        </a>
                    </li>

                    <li>
                        <a href="/to/featurePoint" class="waves-effect">
                            <div class="d-inline-block icons-sm mr-1"><i class="uim uim-chart"></i></div>
                            <span>特征值度量</span>
                        </a>
                    </li>

                    <li>
                        <a href="/to/usecasePoint" class="waves-effect">
                            <div class="d-inline-block icons-sm mr-1"><i class="uim uim-chart-pie"></i></div>
                            <span>用例点度量</span>
                        </a>
                    </li>

                    <li>
                        <a href="/to/objectPoint" class="waves-effect mm-active">
                            <div class="d-inline-block icons-sm mr-1"><i class="uim uim-lock-access"></i></div>
                            <span>对象点度量</span>
                        </a>
                    </li>
                    <li class="menu-title">Oriented Object</li>
                    <li>
                        <a href="/toLK/goToLKMetrics" class="waves-effect">
                            <div class="d-inline-block icons-sm mr-1"><i class="uim uim-sign-in-alt"></i></div>

                            <span>LK度量</span>
                        </a>
                    </li>

                    <li>
                        <a href="/toCK/goToCKMetrics" class="waves-effect">
                            <div class="d-inline-block icons-sm mr-1"><i class="uim uim-grids"></i></div>
                            <span>CK度量</span>
                        </a>
                    </li>

                </ul>
            </div>
            <!-- Sidebar -->
        </div>
    </div>
    <!-- Left Sidebar End -->

    <!-- ============================================================== -->
    <!-- Start right Content here -->
    <!-- ============================================================== -->
    <div class="main-content">

        <div class="page-content">

            <!-- Page-Title -->
            <div class="page-title-box">
                <div class="container-fluid">
                    <div class="row align-items-center">
                        <div class="col-md-8">
                            <h4 class="page-title mb-1">Object Point Metric</h4>
                            <ol class="breadcrumb m-0">
                                <li class="breadcrumb-item active">Welcome to Software Metrics</li>
                            </ol>
                        </div>
                    </div>

                </div>
            </div>
            <div class="page-content-wrapper">
                <div class="container-fluid">
                    <div class="row">
                        <div class="col-12">
                            <div class="card">
                                <div class="card-body">
                                    <div class="row">
                                        <div class="col-6">
                                            <h1>Object Point 度量方法</h1>
                                            <h1>您的项目测试结果:</h1>
                                            <div class="row">
                                                <span class="col-4"><h1 style="color: #3051D3;font-weight: bold;">NOP</h1></span>
                                                <span class="col-8"><h1 style="color: #3051D3;font-weight: bold;" id="resultNOP"></h1></span>
                                            </div>
                                            <div class="row">
                                                <span class="col-4"><h1 style="color: #3051D3;font-weight: bold;">Effort</h1></span>
                                                <span class="col-8"><h1 style="color: #3051D3;font-weight: bold;" id="effort"></h1></span>
                                            </div>

                                            <hr>
                                            <p style="font-size: 15px;color: grey;">
                                            <h5>对象点度量是什么？</h5>
                                            （1）对象点度量方法(ObjectPoint,OP) 对象点度量方法是在软件开发过程中的可行性分析阶段对软件规模进行初步度量的方法。
                                            <br>
                                            （2）将系统中对象分为三类:Screen(界面)、Report(报表)和第三代语言的组件 将三类对象分为简单、一般、复杂三类,根据界面、报表中数据源(表与视图)的数量及来源来评估。
                                            </p>
                                            <div class="mt-4">
                                                <a href="/to/index" class="btn btn-primary btn-sm">了解更多相关内容 <i class="mdi mdi-arrow-right ml-1"></i></a>
                                            </div>
                                        </div>

                                        <div class="col-6 ml-auto">
                                            <div align="right">
                                                <img src="/newImage/pic5.png" alt="" class="img-fluid">
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>

                    <div class="row">
                        <div class="col-6">
                            <div class="card">
                                <div class="card-body">

                                    <h4 style="font-size: 20px;font-weight: bolder" class="header-title">NOP(新对象点)</h4>

                                    <div class="form-group row">
                                        <label  style="color: #3051D3;font-weight: bold" for="screen" class="col-md-6 col-form-label">Screen Number</label>
                                        <div class="col-md-6">
                                            <input class="form-control" type="text" placeholder="请输入整数" id="screen">
                                        </div>
                                    </div>

                                    <div class="form-group row">
                                        <label style="color: #3051D3;font-weight: bold" for="report" class="col-md-6 col-form-label">Report Number</label>
                                        <div class="col-md-6">
                                            <input class="form-control" type="text" placeholder="请输入整数" id="report">
                                        </div>
                                    </div>

                                    <div class="form-group row">
                                        <label style="color: #3051D3;font-weight: bold" for="component" class="col-md-6 col-form-label">Component Number</label>
                                        <div class="col-md-6">
                                            <input class="form-control" type="text" placeholder="请输入整数" id="component">
                                        </div>
                                    </div>

                                    <div class="form-group row">
                                        <label style="color: #3051D3;font-weight: bold" for="data" class="col-md-6 col-form-label">Data Tables Number</label>
                                        <div class="col-md-6">
                                            <input class="form-control" type="text" placeholder="请输入整数" id="data">
                                        </div>
                                    </div>

                                    <div class="form-group row">
                                        <label style="color: #3051D3;font-weight: bold" for="reuse" class="col-md-6 col-form-label">Reuse Rate</label>
                                        <div class="col-md-6">
                                            <input class="form-control" type="text" placeholder="请输入 [ 0,1 ] 之间的小数" id="reuse">
                                        </div>
                                    </div>

                                    <div class="form-group row">
                                        <label style="color: #3051D3;font-weight: bold" class="col-md-6 col-form-label">Productivity</label>
                                        <div class="col-md-6">
                                            <select class="form-control" id="productivity">
                                                <option selected>Very Low</option>
                                                <option>Low</option>
                                                <option>Nominal</option>
                                                <option>High</option>
                                                <option>Very High</option>
                                            </select>
                                        </div>
                                    </div>

                                    <div class="form-group row">
                                        <div class="col-md-12" align="right">
                                            <button type="submit" class="btn btn-primary waves-effect waves-light mr-1" onclick="return calAll();">
                                                Submit
                                            </button>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div> <!-- end col -->
                        <div class="col-6">
                            <div class="card">
                                <div class="card-body">

                                    <h4 style="font-size: 20px;font-weight: bolder" class="header-title">对象点的复杂性级别</h4>
<!--                                    Complexity level for object point-->

                                    <div class="table-responsive">
                                        <table class="table table-editable" style="font-size: 15px">
                                            <thead>
                                                <th style="font-weight: bold">Object Type</th>
                                                <th style="color:#3051d3">Simple</th>
                                                <th style="color:#E6CD38">Medium</th>
                                                <th style="color:#F0694A">Difficult</th>
                                            </thead>
                                            <tr>
                                                <td style="font-weight: bold">Screen</td>
                                                <td> 1 </td>
                                                <td> 2 </td>
                                                <td> 3 </td>
                                            </tr>
                                            <tr>
                                                <td style="font-weight: bold">Report</td>
                                                <td> 2 </td>
                                                <td> 5 </td>
                                                <td> 8 </td>
                                            </tr>
                                            <tr>
                                                <td style="font-weight: bold">Component</td>
                                                <td> -- </td>
                                                <td> -- </td>
                                                <td> 10 </td>
                                            </tr>
                                        </table>

                                    </div>

                                    <br>
                                    <br>
                                    <h4 style="font-size: 20px;font-weight: bolder" class="header-title">开发经验/技能</h4>
<!--                                    Development Experience/Skills-->
                                    <div class="table-responsive">
                                        <table class="table table-editable" style="font-size: 15px">
                                            <thead>
                                            <th></th>
                                            <th style="color:#3DDC97">Very Low</th>
                                            <th style="color:#3A55D4">Low</th>
                                            <th style="color:#E6CE40">Nominal</th>
                                            <th style="color:#00A7E1">High</th>
                                            <th style="color:#F16849">Very High</th>
                                            </thead>
                                            <tr>
                                                <td style="font-weight: bold">Productivity</td>
                                                <td> 4 </td>
                                                <td> 7 </td>
                                                <td> 13 </td>
                                                <td> 25 </td>
                                                <td> 50 </td>
                                            </tr>
                                        </table>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div> <!-- end row -->

                    <div class="row">
                        <div class="col-6">
                            <div class="card">
                                <div class="card-body">

                                    <h4 style="font-size: 20px;font-weight: bolder" class="header-title">屏幕的对象点复杂性级别</h4>
<!--                                    Object point complexity levels for screens-->

                                    <div class="table-responsive">
                                        <table class="table table-editable" style="font-size: 15px">
                                            <tr>
                                                <td rowspan="2" style="color: #3051d3;font-weight: bolder;">Screen Number</td>
                                                <td colspan="3" style="color: #3051d3;font-weight: bolder;">Data Tables Number</td>
                                            </tr>
                                            <tr>
                                                <td style="font-size: 6px;line-height: 200%">Total < 4<br>Servers < 2<br>Clients < 2</td>
                                                <td style="font-size: 6px;line-height: 200%">Total < 8<br>Servers∈(2,3)<br>Clients∈(3,5)</td>
                                                <td style="font-size: 6px;line-height: 200%">Total < 8+<br>Servers > 3<br>Clients > 5</td>
                                            </tr>
                                            <tr>
                                                <td style="color: #3051d3;font-weight: bold"> < 3 </td>
                                                <td><span class="badge badge-soft-primary">Simple</span></td>
                                                <td><span class="badge badge-soft-primary">Simple</span></td>
                                                <td><span class="badge badge-soft-warning">Medium</span></td>
                                            </tr>
                                            <tr>
                                                <td style="color: #3051d3;font-weight: bold"> ( 3,7 ) </td>
                                                <td><span class="badge badge-soft-primary">Simple</span></td>
                                                <td><span class="badge badge-soft-warning">Medium</span></td>
                                                <td><span class="badge badge-soft-danger">Difficult</span></td>
                                            </tr>
                                            <tr>
                                                <td style="color: #3051d3;font-weight: bold"> ≥ 8 </td>
                                                <td><span class="badge badge-soft-warning">Medium</span></td>
                                                <td><span class="badge badge-soft-danger">Difficult</span></td>
                                                <td><span class="badge badge-soft-danger">Difficult</span></td>
                                            </tr>
                                        </table>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="col-6">
                            <div class="card">
                                <div class="card-body">

                                    <h4 style="font-size: 20px;font-weight: bolder" class="header-title">报表的对象点复杂性级别</h4>
<!--                                    Object point complexity levels for reports-->

                                    <div class="table-responsive">
                                        <table class="table table-editable" style="font-size: 15px">
                                            <tr>
                                                <td rowspan="2" style="color: #3051d3;font-weight: bolder;">Reports Number</td>
                                                <td colspan="3" style="color: #3051d3;font-weight: bolder;">Data Tables Number</td>
                                            </tr>
                                            <tr>
                                                <td style="font-size: 6px;line-height: 200%">Total < 4<br>Servers < 2<br>Clients < 2</td>
                                                <td style="font-size: 6px;line-height: 200%">Total < 8<br>Servers∈(2,3)<br>Clients∈(3,5)</td>
                                                <td style="font-size: 6px;line-height: 200%">Total < 8+<br>Servers > 3<br>Clients > 5</td>
                                            </tr>
                                            <tr>
                                                <td style="color: #3051d3;font-weight: bold"> ( 0,1 ) </td>
                                                <td><span class="badge badge-soft-primary">Simple</span></td>
                                                <td><span class="badge badge-soft-primary">Simple</span></td>
                                                <td><span class="badge badge-soft-warning">Medium</span></td>
                                            </tr>
                                            <tr>
                                                <td style="color: #3051d3;font-weight: bold"> ( 2,3 ) </td>
                                                <td><span class="badge badge-soft-primary">Simple</span></td>
                                                <td><span class="badge badge-soft-warning">Medium</span></td>
                                                <td><span class="badge badge-soft-danger">Difficult</span></td>
                                            </tr>
                                            <tr>
                                                <td style="color: #3051d3;font-weight: bold"> ≥ 4 </td>
                                                <td><span class="badge badge-soft-warning">Medium</span></td>
                                                <td><span class="badge badge-soft-danger">Difficult</span></td>
                                                <td><span class="badge badge-soft-danger">Difficult</span></td>
                                            </tr>
                                        </table>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div> <!-- end row -->
                </div>
                <!-- end container-fluid -->
            </div>
            <!-- end page-content-wrapper -->
        </div>
    </div>
    <!-- End Page-content -->
    <footer class="footer">
        <div class="container-fluid">
            <div class="row">
                <div class="col-sm-6">
                    2020 © Software Metric.
                </div>
                <div class="col-sm-6">
                    <div class="text-sm-right d-none d-sm-block">
                        Copyright &copy; 2022.Software Engineering 1901 in CSU All rights reserved.
                    </div>
                </div>
            </div>
        </div>
    </footer>
</div>
<!-- end main content-->

</div>
<!-- END layout-wrapper -->

<script>
    function calNOP()
    {
        var screen,report,component,data,reuse;
        var screenResult,reportResult,result;

        if(document.getElementById("screen").value == "")
        {
            screen = 0;
        }
        else {
            screen = parseInt(document.getElementById("screen").value);
        }

        if(document.getElementById("report").value == "")
        {
            report = 0;
        }
        else {
            report = parseInt(document.getElementById("report").value);
        }

        if(document.getElementById("component").value == "")
        {
            component = 0;
        }
        else {
            component = parseInt(document.getElementById("component").value);
        }

        if(document.getElementById("data").value == "")
        {
            data = 0;
        }
        else {
            data = parseInt(document.getElementById("data").value);
        }

        if(document.getElementById("reuse").value == "")
        {
            reuse = 0;
        }
        else {
            reuse = parseFloat(document.getElementById("reuse").value);
        }

        if(data<= 0 || report<= 0 || screen<=0 || component<=0 || reuse<0 || reuse>1)
        {
            document.getElementById("resultNOP").innerText = "请您输入正确格式哦";
            document.getElementById("resultNOP").style = "color:#FF5252;font-weight: normal";
        }
        else {
            if(data >= 0 && data < 4)
            {
                if(screen>0 && screen < 7)
                {
                    screenResult = screen;
                }
                else
                {
                    screenResult = 2*screen;
                }

                if(report >0 && report <3)
                {
                    reportResult = 2*report;
                }
                else
                {
                    reportResult = 5*report;
                }
            }
            else if(data < 8)
            {
                if(screen>0 && screen < 3)
                {
                    screenResult = screen;
                }
                else if(screen < 7)
                {
                    screenResult = 2*screen;
                }
                else
                {
                    screenResult = 3*screen;
                }

                if(report >0 && report <1)
                {
                    reportResult = 2*report;
                }
                else if(report < 3)
                {
                    reportResult = 5*report;
                }
                else
                {
                    reportResult = 8*report;
                }
            }
            else {
                if(screen>0 && screen < 3)
                {
                    screenResult = screen;
                }
                else
                {
                    screenResult = 3*screen;
                }

                if(report >0 && report <1)
                {
                    reportResult = 2*report;
                }
                else
                {
                    reportResult = 8*report;
                }
            }
        }

        var temp = screenResult + reportResult + 10*component;

        result = temp*(1-reuse);

        if(isNaN(result))
        {
            document.getElementById("resultNOP").innerText = "请您输入正确格式哦";
            document.getElementById("resultNOP").style = "color:#FF5252;font-weight: normal";
        }
        else {
            document.getElementById("resultNOP").innerText = result;
            document.getElementById("resultNOP").style = "color:#3051D3;";
        }

    }
</script>
<script>
    function calEffort()
    {
         var productivity = document.getElementById("productivity").value;
         var nop = parseFloat(document.getElementById("resultNOP").innerText);
         var temp;
         if(productivity == "Very Low")
         {
             temp = 4.00;
         }
         else if(productivity == "Low")
         {
             temp = 7.00;
         }
         else if(productivity == "Nominal")
         {
             temp = 13.00;
         }
         else if(productivity == "High")
         {
             temp = 25.00;
         }
         else
         {
             temp = 50.00;
         }

         var result  = nop / temp;

        if(isNaN(result))
        {
            document.getElementById("effort").innerText = "请您输入正确格式哦";
            document.getElementById("effort").style = "color:#FF5252;font-weight: normal";
        }
        else {
            document.getElementById("effort").innerText = result;
            document.getElementById("effort").style = "color:#3051D3;";
        }

    }
</script>
<script>
    function calAll()
    {
        calNOP();
        calEffort();

        return false;
    }
</script>
<!-- JAVASCRIPT -->
<script src="/js/jquery.min.js"></script>
<script src="/js/bootstrap.bundle.min.js"></script>
<script src="/js/metisMenu.min.js"></script>
<script src="/js/simplebar.min.js"></script>
<script src="/js/waves.min.js"></script>

<script src="/js/bundle.js"></script>

<!-- datepicker -->
<script src="/js/datepicker.min.js"></script>
<script src="/js/datepicker.en.js"></script>

<!-- apexcharts -->
<script src="/js/apexcharts.min.js"></script>

<script src="/js/jquery.knob.min.js"></script>

<!-- Jq vector map -->
<script src="/js/jquery.vmap.min.js"></script>
<script src="/js/jquery.vmap.usa.js"></script>

<script src="/js/dashboard.init.js"></script>

<script src="/js/app.js"></script>

</body>
</html>
